[deps.host]
dynamic-toolchain

[mirrors]
http://tukaani.org/xz/xz-5.0.4.tar.bz2

[main]
filesize=1048328
sha512=a07a05ad02e054e0aba15e293ed7d68d2c636cfb0409fef674cce7fa08ba4a1d958781adf0db0ac364d3761934351e3dc5d40adb743d5e8762a410674732bf63

[build]
printf "all:\n\ttrue\n\ninstall:\n\ttrue\n\n" > tests/Makefile.in
[ -n "$CROSS_COMPILE" ] && \
  xconfflags="--host=$($CC -dumpmachine|sed 's/musl/gnu/')"
# the stage0 arm toolchain has a slightly broken libgcc (with external deps to libc)
# this package is the only one that fails to build.
# so let it depend on the stage1 toolchain. another fix could be to add -lc at the
# end of the gcc invocation in musl-gcc.
CFLAGS="$optcflags" LDFLAGS="$optldflags" \
  ./configure -C --prefix="$butch_prefix" \
    --disable-nls --with-pic --enable-shared \
    --enable-static $xconfflags
make -j$MAKE_THREADS
make DESTDIR="$butch_install_dir" install
